<script>
  /*
   * @Author: Zhang Yingying
   * @Date: 2020-10-24 17:37:30
   * @LastEditors: Zhang Yingying
   * @LastEditTime: 2020-11-07 15:03:50
   */

  import Component from 'vue-class-component'
  import { Prop } from 'vue-property-decorator'
  import BaseControl from './base-control.vue'

  @Component({
    name: 'TextControl',
  })
  export default class TextControl extends BaseControl {
    render(h) {
      var { style, tag, ...rest } = this.$attrs
      return h(tag, {
        attrs: {
          ...rest,
        },
        style,
        domProps: {
          innerHTML: this.value,
        },
      })
    }
  }
</script>
